package com.bw.shopping.mvvm.model;
import com.bw.shopping.entity.AddAdressEntity;
import com.bw.shopping.entity.AddShoppEntity;
import com.bw.shopping.entity.AdressEntity;
import com.bw.shopping.entity.CommodityEntity;
import com.bw.shopping.entity.DelShopEntity;
import com.bw.shopping.entity.DeleteAdressEntity;
import com.bw.shopping.entity.MerchEntity;
import com.bw.shopping.entity.OrderListEntity;
import com.bw.shopping.entity.PaySignEntity;
import com.bw.shopping.entity.PaymentEntity;
import com.bw.shopping.entity.ShoppingEnttiy;
import com.bw.shopping.entity.SubmitCarEntity;
import com.bw.shopping.entity.SubmitOrderEntity;
import com.bw.shopping.entity.UpdateAdressEntity;

import io.reactivex.Observable;
import okhttp3.RequestBody;
import retrofit2.http.Body;
import retrofit2.http.POST;

/**
 * @author KK
 * @description:
 * @date :2021/10/14 15:42
 */
public interface Api {

    @POST("goods/getGoodsList")
    Observable<CommodityEntity> requestCommodity(@Body RequestBody body);

    @POST("goods/getGoodsDetail")
    Observable<MerchEntity> requestMerch(@Body RequestBody body);

    @POST("cart/getList")
    Observable<ShoppingEnttiy> requestShopping(@Body RequestBody body);

    @POST("cart/add")
    Observable<AddShoppEntity> requsetAddshopp(@Body RequestBody body);

    //删除购物车
    @POST("cart/delete")
    Observable<DelShopEntity> requsetdelShopp(@Body RequestBody body);

    //去结算
    @POST("cart/submit")
    Observable<SubmitCarEntity> requestSubmitCar(@Body RequestBody body);

    //订单详情
    @POST("order/getOrderById")
    Observable<OrderListEntity> requestOrderList(@Body RequestBody body);

    //地址列表
    @POST("shipAddress/getList")
    Observable<AdressEntity> requestAdressList(@Body RequestBody body);

    //添加地址
    @POST("shipAddress/add")
    Observable<AddAdressEntity> requestAddAdress(@Body RequestBody body);

    //修改地址
    @POST("shipAddress/modify")
    Observable<UpdateAdressEntity> requestUpdateAdress(@Body RequestBody body);

    //删除地址
    @POST("shipAddress/delete")
    Observable<DeleteAdressEntity> requestDeleteAdress(@Body RequestBody body);

    //提交订单
    @POST("order/submitOrder")
    Observable<SubmitOrderEntity> requestSubmitOrder(@Body RequestBody body);

    //获取支付宝sign
    @POST("pay/getPaySign")
    Observable<PaySignEntity> requestPaySign(@Body RequestBody body);

    //支付状态
    @POST("order/pay")
    Observable<PaymentEntity> requestPayment(@Body RequestBody body);








}
